/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.iceberg.adgt.ui.architecture;

import com.iceberg.adgt.common.*;
import com.iceberg.adgt.domain.LayerDTO;
import com.iceberg.adgt.domain.UnitDTO;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * @author David
 */
public interface ArchitectureController extends Observable, Observer {

	void addLayer(String name, int number) throws DomainException;

	Map<String, LayerDTO> getLayers();

	Set<UnitDTO> getUnitsFromLayer(String name);

	void removeLayer(String name);

	void addUnitToLayer(String unitName, String type) throws DomainException;

	void removeUnitFromLayer() throws ControllerException;

	void setSelectedLayer(String name);

	String getSelectedLayer();

	void setSelectedUnit(UnitDTO unit);

	List<Integer> getUsedLayerNumbers();

	Map<String, LayerDTO> getAvailableAllowedLayers() throws ControllerException;

	Map<String, LayerDTO> getAllowedLayersForLayer() throws ControllerException;

	void addAllowedLayerToLayer(String toLayer) throws DomainException, ControllerException;

	void removeAllowedLayer(String deleteLayer) throws DomainException, ControllerException;

	@Override
	void addObserver(Observer observer, ObserverInterest interest);
}
